<?php

require_once('conf/DBConnection.php');

/**
 * Plugin para manejo de Noticias
 *
 */
class Comercios extends Entity {

	var $id;
	
	public function __construct() {
		parent::__construct();			
	}
	
	function getComercios($categoria) {
		DBConnection::getInstance();
		$query = "SELECT *".
				" FROM comercios AS CO".
				" WHERE CO.categoria  = $categoria ".
				" ORDER BY nombre DESC";
		$result = mysql_query($query);	
		//echo $query;
		return $this->fetch($result);
	}

}

